package org.ddd.productdemo.domaindriven.domain.model.entity;

import org.ddd.productdemo.domaindriven.domain.model.valueobject.Money;

public class OrderLine {

    private ProductId productId;
    private Money price;
    private int quantity;

    private Money subtotal;

    public OrderLine(ProductId productId, Money price, int quantity) {
        this.productId = productId;
        this.price = price;
        this.quantity = quantity;
    }

    public ProductId getProductId() {
        return productId;
    }

    public Money getPrice() {
        return price;
    }

    public int getQuantity() {
        return quantity;
    }

    public Money getSubtotal() {
        return subtotal;
    }
}
